//
//  RCDTextFeidView.h
//  jsy
//
//  Created by  任辰东 on 2020/4/11.
//  Copyright © 2020 JSY. All rights reserved.
//

#import "RCDBaseLayoutView.h"
#import "RCDPlaceholderTextView.h"

NS_ASSUME_NONNULL_BEGIN

@interface RCDTextFeidViewModel : NSObject

@property (nonatomic, copy) NSString *leftImgPath;//左边修饰的小图片的路径
@property (nonatomic, copy) NSString *leftTitle;//左边标题
@property (nonatomic, copy) NSString *rightImgPath;//右边箭头或者其他修饰的小图片的路径
@property (nonatomic, copy) NSString *content;//输入的内容
@property (nonatomic, copy) NSString *placeholder;//输入控件的placeholder，颜色和字体全部统一
@property (nonatomic) BOOL isNotEnable;//是否可点击，默认可点击
@property (nonatomic) BOOL isTextView;//是否开启textview，支持换行自增高
@property (nonatomic) NSInteger limitNum;//字数限制
@property(nonatomic, assign) BOOL secureTextEntry;
//textview最高和最低高度
@property (nonatomic) CGFloat maxHeight;
@property (nonatomic)CGFloat minHeight;

@property (nonatomic) UIReturnKeyType returnKeyType;
@property (nonatomic) UIKeyboardType keyboardType;
@property (nonatomic) NSTextAlignment alignment;
@property (nonatomic, strong) UIColor *leftTitleColor;//左标题颜色
@property (nonatomic, strong) UIColor *contentColor;//输入内容的颜色
@property (nonatomic, strong) UIFont *leftTitleFont;//左标题字体大小
@property (nonatomic, strong) UIFont *contentFont;//输入内容的字体大小

@end

@interface RCDTextFeidView : RCDBaseLayoutView

@property (nonatomic, copy) void(^didSearch)(NSString *search);
@property (nonatomic, copy) void(^textFieldCallBack)(NSString *search);
@property (nonatomic, strong) RCDTextFeidViewModel *model;
@property (nonatomic, strong) RCDPlaceholderTextView *textView;
@property (nonatomic, strong) UITextField *textFeild;

- (instancetype)initWithModel:(RCDTextFeidViewModel *)model;

@end

NS_ASSUME_NONNULL_END
